package com.tfswx.fljdmxyy.query.sjgl;

import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

import java.util.ArrayList;
import java.util.List;

/**
 * 高级查询入参
 *
 * @author 李航
 * @createTime 2022-10-25
 */
@Data
public class DataQueryParam {

    @ApiModelProperty(value = "实体集合")
    private List<Stjh> stjh = new ArrayList<>();

    @ApiModelProperty(value = "展示字段")
    private List<Xszdjh> xszdjh = new ArrayList<>();

    @Data
    public static class Xszdjh {
        @ApiModelProperty(value = "实体表名编号")
        private String stbh;

        @ApiModelProperty(value = "拼接符")
        private String pjf;

        @ApiModelProperty(value = "字段名称")
        private String zdmc;

        @ApiModelProperty(value = "显示名称")
        private String xsmc;
    }

    @Data
    public static class Stjh {

        @ApiModelProperty(value = "实体表名编号")
        private String stbh;

        @ApiModelProperty(value = "实体关系", hidden = true)
        private String stgx;

        @ApiModelProperty(value = "实体关系")
        private List<Stgx> stgxList;

        @ApiModelProperty(value = "字段集合")
        private List<Zdjh> zdjhList;
    }

    @Data
    public static class Zdjh {
        @ApiModelProperty(value = "实体表名编号")
        private String stbh;

        @ApiModelProperty(value = "字段名称")
        private String zdmc;

        @ApiModelProperty(value = "运算符")
        private String ysf;

        @ApiModelProperty(value = "字段值")
        private String zdz;
    }

    @Data
    public static class Stgx {
        @ApiModelProperty(value = "实体表名编号")
        private String stbh;

        @ApiModelProperty(value = "字段名称")
        private String zdmc;
    }
}
